﻿@using AC.Service.DTO.Tools
@using AC.Util
@model wychuan2.com.Areas.admin.Models.MyTaskModel

@{
    ViewBag.Title = "我的任务";
    Layout = "../Shared/_Layout.cshtml";
}

@{
    var lstPrioritys = EnumUtils.GetEnumDescriptions(typeof (TaskPriorityLevel));
}

@section styles{
    <link href="~/Content/plugins/iCheck/custom.css" rel="stylesheet">
}

<div class="row" id="jobs">
    @Html.Partial("_JobList",Model)
</div>

<!--账户对话框-->
<div class="modal fade" id="modalTask" tabindex="-1" role="dialog" aria-labelledby="modalTaskLabel">
    <div class="modal-dialog" role="document">
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
                <h4 class="modal-title" id="modalTaskLabel">创建任务</h4>
            </div>
            <div class="modal-body">
                <form class="form-horizontal" id="frmTask">
                    <input type="hidden" value="0" id="Id" />
                    <div class="form-group">
                        <label class="control-label col-sm-2" for="Title">标题</label>
                        <div class="col-sm-10">
                            <input type="text" class="form-control" id="Title" name="Title" placeholder="请输入标题"  />
                        </div>
                    </div>
                    <div class="form-group">
                        <label class="control-label col-sm-2">优先级</label>
                        <div class="col-sm-10">
                            <select class="form-control" id="PriorityLevel">
                                @foreach (var item in lstPrioritys)
                                {
                                    <option value="@item.Key">@item.Value</option>
                                }
                            </select>
                        </div>
                    </div>
                    <div class="form-group">
                        <label class="control-label col-sm-2" for="Content">任务内容</label>
                        <div class="col-sm-10">
                            <textarea class="form-control" rows="3" id="Content" placeholder="请填写任务信息" required></textarea>
                        </div>
                    </div>
                </form>
            </div>
            <div class="modal-footer">
                <button type="button" class="btn btn-default" data-dismiss="modal">关闭</button>
                <button type="button" id="btnSave" class="btn btn-primary">保存</button>
            </div>
        </div>
    </div>
</div>


@section scripts{
    <script src="~/Scripts/plugins/iCheck/icheck.min.js"></script>
    <script src="~/Scripts/plugins/validate/jquery.validate.min.js"></script>
    <script src="~/Scripts/plugins/validate/messages_zh.js"></script>
    <script src="~/Scripts/tools/myjobs.js"></script>
}